package com.itheima.b_operator;

/**
 * 目标：学习赋值运算符
 * <p>
 * +=   /=
 */
public class Demo05 {

    public static void main(String[] args) {

        int a = 10;
        int b = 3;

        a += 5;   //a=a+5  --->15
        a += b;  //a=a+b  --->13
        System.out.println("a = " + a);

        a /= b;  //等价于  a=a/b=10/3=3
        System.out.println("a = " + a);

        byte m = 10;
        m += 117;       //等价于  m=(byte)m+117--->byte+int,最终结果是int类型，但是扩展运算符隐含了强制类型转换，
        System.out.println("m = " + m);
    }
}
